var moves=0
var callstoZero=0
def hanoi(nDiscs:Int,from:String,to:String,inter:String):Unit ={
    if(nDiscs==0) {
        callstoZero+=1 
    }
    else {
        hanoi(nDiscs-1,from,inter,to)
        moves +=1
        println("move Disc " + nDiscs +  " from " + from  + " to " + to)
        hanoi(nDiscs-1,inter,to,from)
    }
} 


hanoi(5,"A","B","C")
println("-------------")
println(moves)
